package com.coldworks.base;

import com.coldworks.base.util.BaseCONST;
import com.coldworks.coldjoke.R;

import android.os.Bundle;
import android.view.KeyEvent;
import android.webkit.WebSettings;
import android.webkit.WebView;

public class BaseHelpActivity extends BaseActivity {

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.base_help);

		// 加载帮助页面
		WebView wView = (WebView) findViewById(R.id.setting2_help);
		WebSettings wSet = wView.getSettings();
		wSet.setJavaScriptEnabled(true);
		wView.loadUrl(BaseCONST.URL.HELP);

	}

	@Override
	public boolean onKeyDown(int keyCode, KeyEvent event) {
		if (keyCode != KeyEvent.KEYCODE_BACK || event.getRepeatCount() != 0) {
			return super.onKeyDown(keyCode, event);
		}
		// 捕获到返回键
		finish();
		return true;
	}

}
